package net.freestu.sola.web.global;

import java.io.File;
import java.util.ArrayList;


/**
 * Globle Variable of the whole app
 * @author 秋刀鱼的滋味
 */
public class GlobleVar{

	
	public static final String WORKPLACE=ConfigReader.getConfigText("work_place").trim();
	public static final String SCHOOL=ConfigReader.getConfigText("school").trim();
	public static final String SITE=ConfigReader.getConfigText("site").trim();
	public static final String SEED=ConfigReader.getConfigText("seed").trim();
	public static final String SEEDRM=ConfigReader.getConfigText("seedrm").trim();
	public static final int INITSCORE=Integer.valueOf(ConfigReader.getConfigText("initscore").trim());
	public static final int CRAWL_LEVEL=Integer.valueOf(ConfigReader.getConfigText("crawl_level").trim());//指定每只蜘蛛爬行的层数
	public static final boolean BREED_ABL=Boolean.valueOf(ConfigReader.getConfigText("breed_able".trim()));
	public static final String IP_START=ConfigReader.getConfigText("ip_start").trim();
	public static final String IP_END=ConfigReader.getConfigText("ip_end").trim();
	public static final ArrayList ForbidLinks=GlobleOperator.getForbidLinks(new File(ConfigReader.getConfigText("forbidlinksfile").trim()));
	public static final String PAGE_CHARSET=ConfigReader.getConfigText("page_charset").trim();//网页字符集的各种格式。以后可以进行扩展。全部是小写。
	public static final String PAGE_TYPE=ConfigReader.getConfigText("page_type").trim();
	public static final String OTHER_TYPE=ConfigReader.getConfigText("other_type").trim();//.jsp 和js有误
	
	public static final String WEB_NAME="http://";//或者是"http://"
	public static final String EXEFOLDER=WORKPLACE+File.separator+SCHOOL+File.separator+SITE;
	
	public static final ArrayList SEEDS=GlobleOperator.getSeeds();
	
	public static void main(String[] args){
		new GlobleVar();
	}
}